<%-- 
    Document   : sideNavBar
    Created on : 18 Sep 2013, 4:42:57 PM
    Author     : Salman Noor : School of Electrical and Information Engineering
--%>
<%@ include file="/WEB-INF/common/hometaglibs.jsp" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@page import="za.ac.wits.was.enums.SessionAttribute"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>

                <ul id="side-nav-bar-list">
                    <li style="padding-bottom: 10px;">
                        Welcome, 
                        <%  
                out.println(request.getSession().getAttribute(SessionAttribute.UserInformation.name()));
                  String activeLink;
                try{
                   activeLink = request.getAttribute("activeLink").toString();
                }catch(NullPointerException nx){
                activeLink= "";
                }
%>              
                    </li>
                    <security:authorize ifAnyGranted="ROLE_COORDINATOR">
                        
                    <li><a href="<c:url value="/manage/Disciplines"/>" class="<%= (activeLink.equalsIgnoreCase("Disciplines")) ? "k-active-filter":"" %>">Manage Disciplines</a></li>
                    <li><a href="<c:url value="/manage/StaffMembers"/>" class="<%= (activeLink.equalsIgnoreCase("StaffMembers")) ? "k-active-filter":"" %>">Manage Staff Members</a></li>
                    <li><a href="<c:url value="/manage/Courses"/>" class="<%= (activeLink.equalsIgnoreCase("Courses")) ? "k-active-filter":"" %>">Manage Courses</a></li>
                    </security:authorize>
                    <security:authorize ifAnyGranted="ROLE_HOD">
                    <li><a href="<c:url value="/approvals/Allocations"/>" class="<%= (activeLink.equalsIgnoreCase("AllAllocations")) ? "k-active-filter":"" %>">View All Allocations</a></li>
                    <li><a href="<c:url value="/approvals/Allocate"/>" class="<%= (activeLink.equalsIgnoreCase("AllocateCourse")) ? "k-active-filter":"" %>">Allocate Course</a></li>
                    <li><a href="<c:url value="/approvals/Courses"/>" class="<%= (activeLink.equalsIgnoreCase("CourseApprovals")) ? "k-active-filter":"" %>">Approve Course Allocations</a></li>
                    <li><a href="<c:url value="/approvals/Research"/>" class="<%= (activeLink.equalsIgnoreCase("ResearchApprovals")) ? "k-active-filter":"" %>">Approve Research</a></li>
                    </security:authorize>
                    <security:authorize ifAnyGranted="ROLE_STAFF">
                    <li><a href="<c:url value="/allocations/Personal"/>" class="<%= (activeLink.equalsIgnoreCase("PersonalAllocations")) ? "k-active-filter":"" %>">View Personal Allocations</a></li>
                    <li><a href="<c:url value="/allocations/Courses"/>" class="<%= (activeLink.equalsIgnoreCase("CoursesAllocations")) ? "k-active-filter":"" %>">Request Course Allocation</a></li>
                    <li><a href="<c:url value="/allocations/Research"/>" class="<%= (activeLink.equalsIgnoreCase("ResearchAllocations")) ? "k-active-filter":"" %>" >Request Research Allocation</a></li>
                    </security:authorize>
                    <li><a href="<c:url value="/j_spring_security_logout"/>">Logout</a></li>
                    
                    
                </ul>
